package cn.iocoder.yudao.module.agent.service.brokeragewithdrawrecord;

import java.util.*;
import javax.validation.*;
import cn.iocoder.yudao.module.agent.controller.admin.brokeragewithdrawrecord.vo.*;
import cn.iocoder.yudao.module.agent.controller.app.brokeragewithdrawrecord.vo.AppAgentBrokerageWithdrawRecordCreateReqVO;
import cn.iocoder.yudao.module.agent.dal.dataobject.brokeragewithdrawrecord.AgentBrokerageWithdrawRecordDO;
import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.module.agent.enums.AgentBrokerageWithdrawStatusEnum;

/**
 * 代理人佣金提现记录 Service 接口
 *
 * @author 曹建伟
 */
public interface AgentBrokerageWithdrawRecordService {

    /**
     * 创建代理人佣金提现记录
     *
     * @param createReqVO 创建信息
     * @return 编号
     */
    Long createBrokerageWithdrawRecord(@Valid AgentBrokerageWithdrawRecordCreateReqVO createReqVO);

    /**
     * 更新代理人佣金提现记录
     *
     * @param updateReqVO 更新信息
     */
    void updateBrokerageWithdrawRecord(@Valid AgentBrokerageWithdrawRecordUpdateReqVO updateReqVO);

    /**
     * 删除代理人佣金提现记录
     *
     * @param id 编号
     */
    void deleteBrokerageWithdrawRecord(Long id);

    /**
     * 获得代理人佣金提现记录
     *
     * @param id 编号
     * @return 代理人佣金提现记录
     */
    AgentBrokerageWithdrawRecordDO getBrokerageWithdrawRecord(Long id);

    /**
     * 获得代理人佣金提现记录列表
     *
     * @param ids 编号
     * @return 代理人佣金提现记录列表
     */
    List<AgentBrokerageWithdrawRecordDO> getBrokerageWithdrawRecordList(Collection<Long> ids);

    /**
     * 获得代理人佣金提现记录分页
     *
     * @param pageReqVO 分页查询
     * @return 代理人佣金提现记录分页
     */
    PageResult<AgentBrokerageWithdrawRecordDO> getBrokerageWithdrawRecordPage(AgentBrokerageWithdrawRecordPageReqVO pageReqVO);

    /**
     * 获得代理人佣金提现记录列表, 用于 Excel 导出
     *
     * @param exportReqVO 查询条件
     * @return 代理人佣金提现记录列表
     */
    List<AgentBrokerageWithdrawRecordDO> getBrokerageWithdrawRecordList(AgentBrokerageWithdrawRecordExportReqVO exportReqVO);

    /**
     * 代理人请求提现
     *
     * @param createReqVO 提现金额
     * @return 代理人佣金提现记录id
     */
    Long appCreateBrokerageWithdrawRecord(AppAgentBrokerageWithdrawRecordCreateReqVO createReqVO);

    /**
     * 【管理员】审核佣金提现
     *
     * @param id          佣金编号
     * @param status      审核状态
     * @param auditReason 驳回原因
     */
    void auditBrokerageWithdraw(Long id, AgentBrokerageWithdrawStatusEnum status, String auditReason);
}
